home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Leonardo the Inventor
/
Leonardo The Inventor (93026)(Broderbund)(Riverdeep)(2004).iso
/
LEOWINMV
/
DATABASE.DIR
/
00094_Script_PRINT TEXT
< prev
next >
Wrap
Text File
|
1996-03-28
|
1KB
|
50 lines
-- --------------------------------------------------------
-- Handler printTopicText gets the name of the topic to print
-- and then calls printText to print the topic.
on printTopicText
global printButton, browserTopicsLine, textSprite
activateButtonThenEnable(printButton)
set textCastName = the name of cast the castNum of sprite textSprite
set whichTopic = word 1 to (the number of words in textCastName - 1) of textCastName
printText(whichTopic)
end
-- --------------------------------------------------------------
-- Handler printText prints the text of the given topic.
on printText whichTopic
set theText = getAllTextInTopic(whichTopic)
if (the machineType = 256) then
printTextFromPC(theText)
else
printTextFromMac(theText)
end if
end
-- --------------------------------------------------------------
-- Handler getAllTextInTopic returns all the text of the given
-- topic by concatenating the text of the subfields.
on getAllTextInTopic whichTopic
global currentPage
set theText = the text of field (whichTopic && "TEXT" & 1)
set oldCurrentPage = currentPage
resetCurrentPage
set nextPageCast = getNextPageCast(1)
repeat while (nextPageCast <> -1)
set theText = theText && the text of cast nextPageCast
updateCurrentPage(1)
set nextPageCast = getNextPageCast(1)
end repeat
set currentPage = oldCurrentPage
return theText
end